1. Technical Field
The present invention relates to an image processing device, method and program for correcting an image.
2. Related Art
In the related art, in order to give a preferable appearance to a subject of an image, such as a person in a photo, a central portion of the image is reduced and both ends of the image are enlarged such that the aspect ratio of the image is not changed, and the subject person is viewed slimly. Such a slim function may be implemented in a multifunction peripheral (MFP) printer or the like.
The appearance of a person in an image may be further improved by a function for specifying a face region of the person and correcting the contour of the face, such as suggested in JP-A-2004-318204.
However, the subject person is not always located in the center of the image. In the function for slimming the center of the image in the related art, a person that is out of the center may become distorted or big. For example, in the related art, as shown in FIG. 5A, even when the person is out of the center of the image, the process of slimming the image based on the center is performed. In this process, as shown in FIG. 5B, a predetermined range from the center of the image (between lines b-1 and b-4) is set as a reduction region and the range outside of the reduction region is set as an enlargement region. A boundary between the reduction region (b-1 to b-4) and the enlargement region is specified. The image in the reduction region within lines (b-1) and (b-4) is reduced to fit within lines (b-2) and (b-3). Simultaneously, the image in the enlargement region outside of lines (b-1) and (b-4) is enlarged to the region outside of lines (b-2) and (b-3). In this case, as shown in FIG. 5B, a person at a position away from the center of the image is enlarged and becomes distorted or big.
Meanwhile, the technology of JP-A-2004-318204 cannot correct the whole person of the subject by correcting only the face region.